home *** CD-ROM | disk | FTP | other *** search
/ Aminet 7 / Aminet 7 - August 1995.iso / Aminet / game / misc / DiamondCave1_8.lha / Game1.8 / InstallGame next >
Text File  |  1995-06-14  |  12KB  |  382 lines

  1. ; $VER DC-Install 1.8 (14.06.95)
  2.  
  3. (set DrawerNameParent @default-dest)
  4. (set Update 0)
  5. (set version 0)
  6.  
  7. (complete 0)
  8. (if (exists "DC:" (NOREQ))
  9.     (
  10.  
  11.         (set vernum (getversion "DC:DiamondCaves"))
  12.  
  13.         (set ver (/ vernum 65536))
  14.         (set rev (- vernum (* ver 65536)))
  15.  
  16.         (set version (+ (* 100 ver) rev))
  17.  
  18.         (if (> version 107)
  19.             (
  20.                 (message "You have already installed a version greater or equal 1.8!\n")
  21.                 (exit (quiet))
  22.             )
  23.             (
  24.                 (set DrawerNameParent "DC:")
  25.                 (set DrawerName "DC:")
  26.             )
  27.         )
  28.  
  29.         (set Update
  30.             (askchoice
  31.                 (prompt "Diamond Caves V" ver "." rev " already installed.\nDo you want to update or install completely new?")
  32.                 (choices "Install new" "Update")
  33.                 (help "Soory, no help-file.")
  34.                 (default 1)
  35.             )
  36.         )
  37.     )
  38. )
  39.  
  40. (if (= Update 1)                  ; only Update according to present Version
  41.     (
  42.         (if (< version 103)         ; this is only for V1.0/1.1/1.2 (two fixed game levels)
  43.             (
  44.                 (complete 30)
  45.                 (copyfiles
  46.                     (prompt "Copying necessary files to \"" DrawerName "\".")
  47.                     (help @copyfiles-help)
  48.                     (source "UpdateFromV1.0-1.2")
  49.                     (dest DrawerName)
  50.                     (all)
  51.                 )
  52.             )
  53.         )
  54.  
  55.         (if (< version 104)         ; this is the update for V1.0-1.3 (ten new easy levels, one game level)
  56.             (
  57.                 (complete 50)
  58.                 (copyfiles
  59.                     (prompt "Copying necessary files to \"" DrawerName "\".")
  60.                     (help @copyfiles-help)
  61.                     (source "UpdateFromV1.0-1.3")
  62.                     (dest DrawerName)
  63.                     (all)
  64.                 )
  65.             )
  66.         )
  67.  
  68.  
  69.         (if (exists "DC:gfx/x999" (NOREQ))
  70.             (
  71.                 (complete 75)
  72.                 (delete
  73.                         ("DC:gfx/x999")
  74.                         (prompt "Deleting old gfx-file.")
  75.                         (help @deletefile-help)
  76.                 )
  77.             )
  78.         )
  79.  
  80.         (if (< version 106)         ; this is the update for V1.0-1.6 (new gfx-format)
  81.             (
  82.                 (complete 80)
  83.                 (copyfiles
  84.                     (prompt "Copying necessary files to \"" DrawerName "\".")
  85.                     (help @copyfiles-help)
  86.                     (source "UpdateFromV1.0-1.5")
  87.                     (dest DrawerName)
  88.                     (all)
  89.                 )
  90.             )
  91.         )
  92.  
  93.         (if (< version 107)         ; this is the update for V1.0-1.7 (all replay-files and new sfx-format)
  94.             (
  95.                 (complete 90)
  96.                 (copyfiles
  97.                     (prompt "Copying necessary files to \"" DrawerName "\".")
  98.                     (help @copyfiles-help)
  99.                     (source "UpdateFromV1.0-1.6")
  100.                     (dest DrawerName)
  101.                     (all)
  102.                 )
  103.             )
  104.         )
  105.  
  106.         (if (< version 108)         ; this is the update for V1.0-1.8 (main-prg, guide, 3 replay-files)
  107.             (
  108.                 (complete 95)
  109.                 (copyfiles
  110.                     (prompt "Copying necessary files to \"" DrawerName "\".")
  111.                     (help @copyfiles-help)
  112.                     (source "UpdateFromV1.0-1.7")
  113.                     (dest DrawerName)
  114.                     (all)
  115.                 )
  116.             )
  117.         )
  118.  
  119.     )
  120.  
  121.     (                             ; new install: copy everything to "DrawerName"
  122.         (complete 0)
  123.         (set DrawerNameParent
  124.              (askdir
  125.                  (prompt "In which drawer should Diamond Caves V1.8 be installed?\n(A directory called Diamond Caves will be created)")
  126.                  (help @askdir-help)
  127.                  (default DrawerNameParent)
  128.              )
  129.         )
  130.  
  131.         (set DrawerName (tackon DrawerNameParent "DiamondCaves"))
  132.  
  133.         (complete 5)
  134.         (makedir DrawerName
  135.             (prompt "I will now create the directory \"" DrawerName "\".")
  136.             (help @makedir-help)
  137.             (infos)
  138.             (confirm)
  139.         )
  140.  
  141.         (complete 10)
  142.         (set icons
  143.             (askchoice
  144.                 (prompt "What kind of Icons do you want?\n")
  145.                 (choices "normal" "MagicWB" "none")
  146.                 (help "Sorry, no help-file.")
  147.                 (default 0)
  148.             )
  149.         )
  150.  
  151.         (if (= icons 0)
  152.             (
  153.                 (copyfiles
  154.                     (prompt "Copying necessary Icons to \"" DrawerName "\".")
  155.                     (help @copyfiles-help)
  156.                     (source "Icons/normal")
  157.                     (dest DrawerName)
  158.                     (all)
  159.                     (infos)
  160.                 )
  161.             )
  162.         )
  163.         (if (= icons 1)
  164.             (
  165.                 (copyfiles
  166.                     (prompt "Copying necessary Icons to \"" DrawerName "\".")
  167.                     (help @copyfiles-help)
  168.                     (source "Icons/MagicWB")
  169.                     (dest DrawerName)
  170.                     (all)
  171.                     (infos)
  172.                 )
  173.             )
  174.         )
  175.  
  176.  
  177.         (complete 20)
  178.         (copyfiles
  179.             (prompt "Copying necessary files to \"" DrawerName "\".")
  180.             (help @copyfiles-help)
  181.             (source "new")
  182.             (dest DrawerName)
  183.             (all)
  184.             (infos)
  185.         )
  186.  
  187.         (complete 30)
  188.         (copyfiles
  189.             (prompt "Copying necessary files to \"" DrawerName "\".")
  190.             (help @copyfiles-help)
  191.             (source "UpdateFromV1.0-1.2")
  192.             (dest DrawerName)
  193.             (all)
  194.         )
  195.  
  196.         (complete 40)
  197.         (copyfiles
  198.             (prompt "Copying necessary files to \"" DrawerName "\".")
  199.             (help @copyfiles-help)
  200.             (source "UpdateFromV1.0-1.3")
  201.             (dest DrawerName)
  202.             (all)
  203.         )
  204.  
  205.         (complete 50)
  206.         (copyfiles
  207.             (prompt "Copying necessary files to \"" DrawerName "\".")
  208.             (help @copyfiles-help)
  209.             (source "UpdateFromV1.0-1.5")
  210.             (dest DrawerName)
  211.             (all)
  212.         )
  213.  
  214.         (complete 60)
  215.         (copyfiles
  216.             (prompt "Copying necessary files to \"" DrawerName "\".")
  217.             (help @copyfiles-help)
  218.             (source "UpdateFromV1.0-1.6")
  219.             (dest DrawerName)
  220.             (all)
  221.         )
  222.  
  223.         (complete 65)
  224.         (copyfiles
  225.             (prompt "Copying necessary files to \"" DrawerName "\".")
  226.             (help @copyfiles-help)
  227.             (source "UpdateFromV1.0-1.7")
  228.             (dest DrawerName)
  229.             (all)
  230.         )
  231.  
  232.         (complete 70)
  233.         (startup "Diamond Caves"
  234.             (prompt "An assign to \"DC:\" will be added to \"S:user-startup\" so that your system will be properly configured to use Diamond Caves.")
  235.             (help "Sorry, no help-file.")
  236.             (command "assign DC: \"" DrawerName "\"")
  237.         )
  238.         (makeassign "DC")
  239.         (makeassign "DC" DrawerName)
  240.  
  241.  
  242.         (complete 75)
  243.         (if ((database "vblank") 50)
  244.             (set DefaultMode 0)
  245.             (set DefaultMode 2)
  246.         )
  247.         (set ScreenModeNum
  248.             (askchoice
  249.                 (prompt "Which screenmode do you want the title screen of Diamond Caves to use?\n(Note that the title was designed to be used on an interlaced screenmode)")
  250.                 (choices "PAL:HighRes" "PAL:HighRes Interlace" "NTSC:HighRes" "NTSC:HighRes Interlace")
  251.                 (help "Soory, no help-file.")
  252.                 (default DefaultMode)
  253.             )
  254.         )
  255.         (if (= ScreenModeNum 0)
  256.             (set ScreenMode "PAL")
  257.         )
  258.         (if (= ScreenModeNum 1)
  259.             (set ScreenMode "PAL-LACE")
  260.         )
  261.         (if (= ScreenModeNum 2)
  262.             (set ScreenMode "NTSC")
  263.         )
  264.         (if (= ScreenModeNum 3)
  265.             (set ScreenMode "NTSC-LACE")
  266.         )
  267.         (tooltype 
  268.             (prompt "I will now change the tooltype TITLEMODE to " ScreenMode ".")
  269.             (help "Soory, no help-file.")
  270.             (dest "DC:DiamondCaves")
  271.             (settooltype "TITLEMODE" ScreenMode)
  272.             (confirm)
  273.         )
  274.  
  275.  
  276.         (complete 80)
  277.         (set ScreenModeNum
  278.             (askchoice
  279.                 (prompt "Which screenmode do you want the game to use?\n(Note that you should only use interlace if you have a 17\" monitor)")
  280.                 (choices "PAL:LowRes" "PAL:HighRes Interlace" "NTSC:LowRes" "NTSC:HighRes Interlace")
  281.                 (help "Soory, no help-file.")
  282.                 (default DefaultMode)
  283.             )
  284.         )
  285.         (if (= ScreenModeNum 0)
  286.             (set ScreenMode "PAL")
  287.         )
  288.         (if (= ScreenModeNum 1)
  289.             (set ScreenMode "PAL-LACE")
  290.         )
  291.         (if (= ScreenModeNum 2)
  292.             (set ScreenMode "NTSC")
  293.         )
  294.         (if (= ScreenModeNum 3)
  295.             (set ScreenMode "NTSC-LACE")
  296.         )
  297.         (tooltype 
  298.             (prompt "I will now change the tooltype GAMEMODE to " ScreenMode ".")
  299.             (help "Soory, no help-file.")
  300.             (dest "DC:DiamondCaves")
  301.             (settooltype "GAMEMODE" ScreenMode)
  302.             (confirm)
  303.         )
  304.  
  305.  
  306.         (complete 85)
  307.         (set ControlNum
  308.             (askchoice
  309.                 (prompt "Which controlling device do you want Player 1 to use?\n")
  310.                 (choices "Joystick Port 1" "Joystick Port 2" "Keyboard")
  311.                 (help "Soory, no help-file.")
  312.                 (default 1)
  313.             )
  314.         )
  315.         (if (= ControlNum 0)
  316.             (set ControlMode "JOY1")
  317.         )
  318.         (if (= ControlNum 1)
  319.             (set ControlMode "JOY2")
  320.         )
  321.         (if (= ControlNum 2)
  322.             (set ControlMode "KEYS")
  323.         )
  324.         (tooltype 
  325.             (prompt "I will now change the tooltype PLAYER1 to " ControlMode ".")
  326.             (help "Soory, no help-file.")
  327.             (dest "DC:DiamondCaves")
  328.             (settooltype "PLAYER1" ControlMode)
  329.             (confirm)
  330.         )
  331.  
  332.  
  333.         (complete 90)
  334.         (set ControlNum
  335.             (askchoice
  336.                 (prompt "Which controlling device do you want Player 2 to use?\n")
  337.                 (choices "Joystick Port 1" "Joystick Port 2" "Keyboard")
  338.                 (help "Soory, no help-file.")
  339.                 (default 0)
  340.             )
  341.         )
  342.         (if (= ControlNum 0)
  343.             (set ControlMode "JOY1")
  344.         )
  345.         (if (= ControlNum 1)
  346.             (set ControlMode "JOY2")
  347.         )
  348.         (if (= ControlNum 2)
  349.             (set ControlMode "KEYS")
  350.         )
  351.         (tooltype 
  352.             (prompt "I will now change the tooltype PLAYER2 to " ControlMode ".")
  353.             (help "Sorry, no help-file.")
  354.             (dest "DC:DiamondCaves")
  355.             (settooltype "PLAYER2" ControlMode)
  356.             (confirm)
  357.         )
  358.  
  359.         (complete 95)
  360.         (if (askbool
  361.                 (prompt "Do you want to access the hardware directly instead of using the gameport.device?\n(This is faster but not OS-friendly)")
  362.                 (help "Soory, no help-file.")
  363.                 (default 0)
  364.             )
  365.             (set GamePort "OFF")
  366.             (set GamePort "ON")
  367.         )
  368.         (tooltype 
  369.             (prompt "I will now change the tooltype GAMEPORTDEVICE to " GamePort ".")
  370.             (help "Soory, no help-file.")
  371.             (dest "DC:DiamondCaves")
  372.             (settooltype "GAMEPORTDEVICE" GamePort)
  373.             (confirm)
  374.         )
  375.     )
  376. )
  377.  
  378. (complete 100)
  379. (message "\nDiamond Caves installation/update complete, please make sure to read at least the first chapter of the doc-file.\n\nAnd now enjoy Diamond Caves V1.8!")
  380.  
  381. (exit (quiet))
  382.